function androidLinearCode(cache) {
  var code = `
    <LinearLayout
        android:id="@+id/${cache.data.id}"
        android:layout_width="WRAP_CONTENT"
        android:layout_height="WRAP_CONTENT"
    `;
  if (cache.attrs) {
    for (var i = 0; i < cache.attrs.length; i++) {
      var attr = cache.attrs[i];
      code += attr + "\n";
    }
  }
  code += ">";
  if (cache.type == "row") {
    code += `android:orientation="horizontal"`;
  } else if (cache.type == "column") {
    code += `android:orientation="vertical"`;
  }

  if (cache.children && cache.children.length > 0) {
    for (var i = 0; i < cache.children.length; i++) {
      var child = cache.children[i];
      code += exportXmlByType(child);
    }
  }
  code += `
    </LinearLayout>
    `;
  return code;
}
